<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ include file="/include/taglibs.jsp" %>
<html>
<head>
    <%@include file="/include/header.html" %>
    <script type="text/javascript" src="${ctx}/appjs/log/tenantChargeLog.js"></script>
    <link rel="stylesheet" href="${ctx}/statics/css/update.css?v=20200825">
    <link rel="stylesheet" href="${ctx}/statics/css/common.css?v=20200825">
    <link rel="stylesheet" href="${ctx}/libjs/plugins/bootstrap-table-pagejump/bootstrap-table-pagejump.css">
    <script src="${ctx}/libjs/plugins/bootstrap-table-pagejump/bootstrap-table-pagejump.js"></script>
    <%--<link rel="stylesheet" href="${ctx}/libjs/plugins/laydate/skins/laydate.css">--%>
    <link rel="stylesheet" href="${ctx}/libjs/plugins/laydate/laydate.css">
    <script src="${ctx}/libjs/plugins/laydate/laydate.js"></script>
</head>

<script type="text/javascript">
    $('#topLink', window.parent.document).html(function (i, origText) {
        return '<ol class="breadcrumb">' +
            '<li class="breadcrumb-item">' +
            '<a href="">主页</a>' +
            '</li>' +
            '<li class="breadcrumb-item">' +
            '<a>日志</a>' +
            '</li>' +
            '<li class="breadcrumb-item">' +
            '<strong>订单充电日志</strong>' +
            '</li>' +
            '</ol>';
    });
</script>

<body class="gray-bg">
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="col-sm-12">
        <div class="ibox">
            <div class="ibox-body">
                <div class="row">
                    <input id="operatorName" type="text" class="form-control longInput"
                           placeholder="请输入加盟商名称">
                    <input id="nickName" type="text" placeholder="请输入用户名" class="form-control longInput input-distance">
                    <input id="gunNo" type="text" placeholder="请输入充电枪编号" class="form-control longInput input-distance">

                </div>
                <div class="row">
                    <input id="orderNum" type="text" class="form-control longInput"
                           placeholder="订单号">
                    <input id="startTime" name="startTime" type="text"
                           class="form-control layer-date input-distance timeInput"
                           placeholder="开始时间">
                    <input id="endTime" name="endTime" type="text"
                           class="form-control layer-date input-distance timeInput"
                           placeholder="结束时间">
                    <button class="btn btn-success input-distance" onclick="tenantChargeLog.reLoad()">查询</button>
                    <button class="btn btn-success input-distance exportBtn" onclick="tenantChargeLog.exportList()">导出</button>
                </div>
                <table id="exampleTable" data-mobile-responsive="true">
                </table>
            </div>
        </div>
    </div>
</div>

<script>
    layui.use('laydate', function () {
        var laydate = layui.laydate;

        var collectionDate = laydate.render({
            elem: '#queryTime',
            type: 'date',
            format: 'yyyy-MM-dd HH:mm:ss',
            trigger: 'click'
        });

    });

    // //日期范围限制
    var start = {
        elem: '#startTime',
        format: 'YYYY-MM-DD hh:mm:ss',
        // theme: '#3195f0',
        // min: laydate.now(), //设定最小日期为当前日期
        // max: '2099-06-16 23:59:59', //最大日期
        istime: true,
        istoday: false,
        choose: function (datas) {
            $("#endTime").val("")
            end.min = datas
        }
    };
    var end = {
        elem: '#endTime',
        format: 'YYYY-MM-DD hh:mm:ss',
        // theme: '#3195f0',
        // min: laydate.now(),
        // max: '2099-06-16 23:59:59',
        istime: true,
        istoday: false,
        choose: function (datas) {
            start.max = datas; //结束日选好后，重置开始日的最大日期
        }
    };
    laydate(start);
    laydate(end);
    laydate.skin('molv');//皮肤
    tenantChargeLog.init();
</script>
</body>
</html>
